package com.example.administrator.yuejian_15.model;


import com.example.administrator.yuejian_15.bean.RegistBean;
import com.example.administrator.yuejian_15.iface.RegistIface;
import com.example.administrator.yuejian_15.listener.TListener;
import com.example.administrator.yuejian_15.service.AllService;

import retrofit2.Call;
import retrofit2.Retrofit;

public class RegistModel extends RetrofitBaseModel implements RegistIface<RegistBean> {
    private AllService allService;
    private Retrofit retrofit;
    public RegistModel(){
        retrofit=getRetrofit();
        allService=getAllService();
    }

    @Override
    public void regist(String username, String password, String phone, String email, TListener<RegistBean> tListener) {
        Call<RegistBean> call = allService.registe(username,password,phone,email);
        callenqueue(call,tListener);
    }
}
